package com.violet.common.page;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.Min;
import java.io.Serializable;

/**
 * @Author: wqf
 * @Date: 2022/07/29
 * @Description: 分页查询入参参数封装实体
 */
@Getter
@Setter
public class PageParam implements Serializable {
    /**
     * 每页记录数
     * 不传则表示查寻全部数据
     */
    @Min(value = 1)
    @Schema(description = "每页数据", example = "10")
    private Integer current = Integer.MAX_VALUE;
    /**
     * 当前页
     */
    @Min(value = 1)
    @Schema(description = "当前页", example = "1")
    private Integer size = 1;
}
